<style>
.new-lay-span{
    display: inline-block;
    width: 45%!important;
    line-height: 3rem;
}
</style>





<div class="x-body">
    <h3>基本信息</h3>
    <hr>
    <form class="layui-form form_single" id="form" action="{:url()}" method="post">

        <div class="layui-form-item">

            <span class=" new-lay-span"> 订单号 ：{$info.otcorder.serial_number}</span>
            <span class="layui-input-inline new-lay-span"> 创建时间 ：{$info.otcorder.create_time}</span>
        </div>
        <div class="layui-form-item">
            <span class="layui-input-inline new-lay-span"> 订单数量 ：{$info.otcorder.number}</span>

        </div>
        <div class="layui-form-item">
            <span class="layui-input-inline new-lay-span"> 订单单价 ：{$info.otcorder.price}</span>

        </div>

        <div class="layui-form-item">
            <span class="layui-input-inline new-lay-span"> 订单总价 ：{$info.otcorder.total}</span>


        </div>
        <div class="layui-form-item">
            <span class="layui-input-inline new-lay-span"> 订单状态 ：{$info.otcorder.state_text}</span>


        </div>



        <hr>
        <h3>买家信息</h3>
        <hr>
        <div class="layui-form-item">
            <span class="layui-input-inline new-lay-span"> 会员账号 ：{$info.otcorder.member->username}</span>
            <span class="layui-input-inline new-lay-span"> 手机号码 ：{$info.otcorder.member.mobile}</span>

        </div>


        <hr>


        <h3>卖家信息</h3>
        <hr>
        <div class="layui-form-item">
            <span class="layui-input-inline new-lay-span"> 会员账号 ：{$info.otcorder.user->username}</span>
            <span class="layui-input-inline new-lay-span"> 手机号码 ：{$info.otcorder.user.mobile}</span>

        </div>
        <hr>
        <h3>投诉处理</h3>
        <hr>
        <div class="layui-form-item" >
            <label class="layui-form-label">处理类型</label>
            <div class="layui-input-block">
                <input type="radio" lay-filter="test" name="type_text" value="买家类型" title="买家类型"    checked >
                <input type="radio" lay-filter="test" name="type_text" value="店铺类型" title="店铺类型"    >
            </div>
        </div>
        <div class="buy_user">

            <div class="layui-form-item">
                <label class="layui-form-label">处理方式</label>
                <div class="layui-input-block">
                    <input type="radio" name="real" value="0" title="买家已打款" >
                    <input type="radio" name="real" value="2" title="买家未打款" >
                    <input type="radio" name="real" value="3" title="买家重新打款" >
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">惩罚机制</label>
                <div class="layui-input-block">
                    <input type="radio" name="punish" value="0" title="不扣除惩罚金" >
                    <input type="radio" name="punish" value="1" title="扣除惩罚金" >

                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">冻结机制</label>
                <div class="layui-input-block">
                    <input type="radio" name="freeze" value="0" title="不冻结账号" >
                    <input type="radio" name="freeze" value="1" title="冻结账号" >

                </div>
            </div>
            <div class="layui-form-item">
                <label for="buy_days" class="layui-form-label">
                    惩罚买家天数
                </label>
                <div class="layui-input-block">
                    <input type="number" id="buy_days" name="buy_days"
                           autocomplete="off" class="layui-input"  >
                </div>
                <div class="layui-form-mid layui-word-aux">
                    ( 惩罚买家天数)
                </div>
            </div>


        </div>
        <div class="sell_user" style="display: none">

            <div class="layui-form-item">
                <label class="layui-form-label">处理方式</label>
                <div class="layui-input-block">
                    <input type="radio" name="real" value="1" title="店铺已放行" >

                    {if condition="$info.otcorder.withdrwal_id gt 0"}<input type="radio" name="real" value="4" title="店铺打款超时，转移重新匹配订单" >{/if}
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">惩罚机制</label>
                <div class="layui-input-block">
                    <input type="radio" name="punish" value="0" title="不扣除惩罚金" >
                    <input type="radio" name="punish" value="2" title="扣除惩罚金" >

                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">冻结机制</label>
                <div class="layui-input-block">
                    <input type="radio" name="freeze" value="0" title="不冻结账号" >
                    <input type="radio" name="freeze" value="2" title="冻结账号" >
                </div>
            </div>
            <div class="layui-form-item">
                <label for="credit" class="layui-form-label">
                    扣除信用分
                </label>
                <div class="layui-input-block">
                    <input type="number" id="credit" name="credit"
                           autocomplete="off" class="layui-input"  >
                </div>
                <div class="layui-form-mid layui-word-aux">
                    (信用分)
                </div>
            </div>
            <div class="layui-form-item">
                <label for="shop_days" class="layui-form-label">
                    惩罚店铺天数
                </label>
                <div class="layui-input-block">
                    <input type="number" id="shop_days" name="shop_days"
                           autocomplete="off" class="layui-input"  >
                </div>
                <div class="layui-form-mid layui-word-aux">
                    (惩罚店铺天数)
                </div>
            </div>
            <div class="layui-form-item">
                <label for="no_match_days" class="layui-form-label">
                    禁止匹配天数
                </label>
                <div class="layui-input-block">
                    <input type="number" id="no_match_days" name="no_match_days"
                           autocomplete="off" class="layui-input"  >
                </div>
                <div class="layui-form-mid layui-word-aux">
                    (禁止匹配天数)
                </div>
            </div>
        </div>
        <div class="layui-form-item">
            <label for="username" class="layui-form-label">
              说明：
            </label>
            <div class="layui-input-block">
                <input type="text" id="username" name="feedback_content" onchange="this.value=this.value.substring(0, 200)" onkeydown="this.value=this.value.substring(0, 200)" onkeyup="this.value=this.value.substring(0, 30)" required="" lay-verify="required"
                       autocomplete="off"   class="layui-input">
            </div>
            <div style="color: red !important;" class="layui-form-mid layui-word-aux">
                （限制200字符）
            </div>
        </div>
        <hr>
        <input type="hidden" name="id" value="{$info['id']}"/>
        <div class="box-footer">
        <button type="submit"  class="layui-btn ladda-button ajax-post" data-style="slide-up" target-form="form_single">
            确 定
        </button>
        <a class="layui-btn ladda-button" onclick="javascript:history.back(-1);return false;"><i class="fa fa-history"></i> 返 回</a>
        </div>


    </form>
</div>

<script>
    layui.use('form', function(){
        var form = layui.form;

        //各种基于事件的操作，下面会有进一步介绍
        form.on('radio(test)', function(data){
            if(data.value=='店铺类型'){
                $('.buy_user').hide();
                $('.sell_user').show();
            }else{
                $('.buy_user').show();
                $('.sell_user').hide();
            }
            form.render();
            console.log(data.value); //被点击的radio的value值
        });
    });

</script>
